package com.y2.authprj.bean.auth.vo;

import java.io.Serializable;
import java.util.Date;

import org.springframework.format.annotation.DateTimeFormat;

import com.y2.authprj.utils.DateUtil;

public class StaffInfoVo implements Serializable{
	/**
	 * 
	 */
	private static final long serialVersionUID = 3956558048286403405L;
	
	private int staffId;
	private String staffNum;
	private String chnName;
	private String surName;
	private String mobile;
	private String pwd;
	private int changePwd;
	private int deleteFlag;
	private String loginIp;
	private int logStatus;
	private String sysroleName;
	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
	private Date createTime;
	private String createTimeStr;
	
	private String name;
	private String beginDate;
	//每页的行数
	private Integer num=5;
	//第几页
	private Integer pageNum =1;
	
	

	public String getChnName() {
		return chnName;
	}
	public void setChnName(String chnName) {
		this.chnName = chnName;
	}
	public String getSysroleName() {
		return sysroleName;
	}
	public void setSysroleName(String sysroleName) {
		this.sysroleName = sysroleName;
	}
	public Date getCreateTime() {
		return createTime;
	}
	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}
	public String getCreateTimeStr() {
		return DateUtil.formate(createTime);
	}
	public void setCreateTimeStr(String createTimeStr) {
		this.createTimeStr = createTimeStr;
	}
	public String getBeginDate() {
		return beginDate;
	}
	public void setBeginDate(String beginDate) {
		this.beginDate = beginDate;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public Integer getNum() {
		return num;
	}
	public void setNum(Integer num) {
		if(null==num||num<=0){
			num = 5;
		}
		this.num = num;
	}
	public Integer getPageNum() {
		return pageNum;
	}
	public void setPageNum(Integer pageNum) {
		if(null==pageNum||pageNum<=0){
			pageNum = 1;
		}
		this.pageNum = pageNum;
	}
	
	public Integer getBegin(){
		return (pageNum-1)*num;
	}
	
	public int getStaffId() {
		return staffId;
	}
	public void setStaffId(int staffId) {
		this.staffId = staffId;
	}
	public String getStaffNum() {
		return staffNum;
	}
	public void setStaffNum(String staffNum) {
		this.staffNum = staffNum;
	}
	
	public String getSurName() {
		return surName;
	}
	public void setSurName(String surName) {
		this.surName = surName;
	}
	public String getPwd() {
		return pwd;
	}
	public void setPwd(String pwd) {
		this.pwd = pwd;
	}
	public String getMobile() {
		return mobile;
	}
	public void setMobile(String mobile) {
		this.mobile = mobile;
	}
	public int getChangePwd() {
		return changePwd;
	}
	public void setChangePwd(int changePwd) {
		this.changePwd = changePwd;
	}
	public int getDeleteFlag() {
		return deleteFlag;
	}
	public void setDeleteFlag(int deleteFlag) {
		this.deleteFlag = deleteFlag;
	}
	
	public String getLoginIp() {
		return loginIp;
	}
	public void setLoginIp(String loginIp) {
		this.loginIp = loginIp;
	}
	
	public int getLogStatus() {
		return logStatus;
	}
	public void setLogStatus(int logStatus) {
		this.logStatus = logStatus;
	}
	@Override
	public String toString() {
		return "StaffInfoVo [staffId=" + staffId + ", staffNum=" + staffNum + ", chnName=" + chnName + ", surName="
				+ surName + ", mobile=" + mobile + ", pwd=" + pwd + ", changePwd=" + changePwd + ", deleteFlag="
				+ deleteFlag + ", loginIp=" + loginIp + ", logStatus=" + logStatus + ", sysroleName=" + sysroleName
				+ ", createTime=" + createTime + ", createTimeStr=" + createTimeStr + ", name=" + name + ", beginDate="
				+ beginDate + ", num=" + num + ", pageNum=" + pageNum + "]";
	}

	
	
	
}
